package com.nativetalk.dao;

import com.nativetalk.bean.member.course.TdNtMembCourseSize;

import java.util.Map;

/**
 * Created by wangzheng on 2017/2/16.
 */
@MyBatisRepository
public interface TdNtMembCourseSizeDao {
    /**
     * @param map
     * @return TdNtMembCourseSize
     * @Purpose 根据用户id和课程id查找课程剩余的次数
     * @version 4.1
     * @author wangzheng
     */
    public TdNtMembCourseSize findTdNtMembCourseSizeByMembIdAndCouId(Map<String, Object> map);

    /**
     * @param tdNtMembCourseSize
     * @return void
     * @Purpose 更新用户购买的某一课程的剩余次数
     * @version 4.1
     * @author wangzheng
     */
    public void updateTdNtMembCourseSizeByMembIdAndCouId(TdNtMembCourseSize tdNtMembCourseSize);

    /**
     * @param tdNtMembCourseSize
     * @return void
     * @Purpose 用户购买某一课程后插入该课程的规格次数(第一次购买)
     * @version 4.1
     * @author wangzheng
     */
    public void insertTdNtMembCourseSize(TdNtMembCourseSize tdNtMembCourseSize);
}
